package com.heima.corss.controller;

import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashSet;

/**
 * @author jack
 * @data 2024 17:11
 */
@RestController
@RequestMapping("student")
public class StudentController {


    @PostMapping("add")
    public String add(String name){
        HashSet<String> hs = new HashSet<>();
        hs.add("hello");

        System.out.println("添加学生：name = " + name);
        return "success";
    }


    public static void main(String[] args) {
        System.out.println(-1 % 16);


        System.out.println( 15 & 1 );
        /*
                15的二进制：      000000000 000000000 000000000 00001111
                1的二进制：  &    000000000 000000000 000000000 00000001
                --------------------------------------------------------------
                                  000000000 000000000 000000000 00000001
         */


    }


}
